//
//  CollectTableViewCell.m
//  BeautifulShoppings
//
//  Created by GivenBmli on 16/9/5.
//  Copyright © 2016年 GivenBmli. All rights reserved.
//

#import "CollectTableViewCell.h"
#import "TAMacro.h"
@implementation CollectTableViewCell

- (instancetype)initWithStyle:(UITableViewCellStyle)style reuseIdentifier:(NSString *)reuseIdentifier {
    self = [super initWithStyle:style reuseIdentifier:reuseIdentifier];
    if (self) {
        [self creatSubView];
    }
    return self;
}
- (void)creatSubView {
    self.photo = [[UIImageView alloc]initWithFrame:CGRectMake(SCREEN_WIDTH / 30, 0, SCREEN_WIDTH - SCREEN_WIDTH/ 15, SCREEN_WIDTH / 2.1)];
    
    self.photo.backgroundColor = [UIColor
                                  redColor];
    [self.contentView addSubview:self.photo];
    
    
    UIView *viewDown = [[UIView alloc]initWithFrame:CGRectMake(SCREEN_WIDTH / 30,SCREEN_WIDTH / 2 -SCREEN_HEIGHT / 15, SCREEN_WIDTH - SCREEN_WIDTH / 15, SCREEN_HEIGHT / 15)];
    viewDown.backgroundColor = [UIColor lightGrayColor];
    
    viewDown.alpha = 0.3;
    [self.contentView addSubview:viewDown];
    self.name = [[UILabel alloc]initWithFrame:CGRectMake(SCREEN_WIDTH / 30, SCREEN_WIDTH / 2 -SCREEN_HEIGHT / 15 , SCREEN_WIDTH - SCREEN_WIDTH / 15, SCREEN_HEIGHT / 15)];
    self.name.textColor = [UIColor blackColor];
    [self.contentView addSubview:self.name];
}
@end